package com.cwz.api.remote;

import com.cwz.api.factory.RemoteSeataDemoFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;

/**
 * @program: w-demo
 * @description: seata demo 测试服务 feign
 * @author: Wen
 **/
@FeignClient(contextId = "remoteSeataDemoService", value = "cwz-seata-demo1", fallbackFactory = RemoteSeataDemoFallbackFactory.class)
public interface RemoteSeataDemoService {
	@PutMapping("/seata-demo/upd/num/{id}")
	public int updateNum(@PathVariable("id") Long id);

	@PutMapping("/seata-demo/upd/price/{id}")
	public int updatePrice(@PathVariable("id") Long id);

	@PostMapping("/seata-demo/add")
	public int addSeataDemo();
}
